<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>百度一下</title>
    <script src="jquery/jquery-3.5.1.js"></script>
</head>
<body>
    <input type = "text" id = "search" /> <button id = "baidu">百度一下</button>
    <script>
        // 这里演示了四种操作行为： 1. 单击事件   2. 获取输入框的值    3. 盗链    4.get请求
        $(function () {
            $("#baidu").click(function () {
                var search_value = $("#search").val();
                window.location.href = "https://www.baidu.com/s?wd=" + search_value;
            });
        })
    </script>

</body>
</html>